<?php 
// Description: add task form
// Created by /task/partials/add_task view
// Variables:
//		- $project: current project 
//		- $users: user list of that project
$curr_user = Helper_Auth::instance()->get_user();
?>



	<tr class="row edit-task show" style="display:none">
				<td colspan="6">
					<form method="post" accept-charset="utf-8" id="add-task-form">
						<div class="wrap-edit-task">
		 					<label>
		 						<strong>Title :</strong>
		 						<input type="text" name="name" value="">
		 					</label>
		 					<label>
		 						<strong>Description :</strong>
		 						<textarea name="decription"></textarea>
		 					</label>
		 					<div style="width:100%">
		 					<label class="quarter">
		 						<strong>Deadline :</strong>
		 						<input type="text" class="deadline small" name="deadline" value="">
		 					</label>
		 					<label class="quarter">
		 						<strong>Assign to :</strong>
		 						<select name="assign_user_id" class="assign_user_id">
		 						    
		 							<option value="1">To Anh</option>
		 							<option value="2">Loc Nguyen</option>
		 						</select>
		 					</label>
		 					<label class="quarter">
		 						<strong>Priority :</strong>
		 						<select name="priority">
		 							<option>Low</option>
		 							<option>Medium</option>
		 							<option>High</option>
		 						</select>
		 					</label>
		 					<label class="quarter bottom">
		 						<button name="save" onClick="add_task(event)" class="save">Save</button>
		 						<a class="cancel" href="#">Cancel	</a>
	 						</label>
	 						</div>
 					</div>
 					</form>
				</td>
	</tr>
	
	<?php /*
	h7>Create new task in <b>PROJECT</b></h7>
	
	<table class="group">
		<tr class="rowA">
			<td>Task name </td>
			<td><?php echo form::input('name', '', array('class'=> 'task_name', 'size' => 100))?></td>
		</tr>
	</table>
	<table class="group">
		<tr class="rowA">
			<?php if(isset($projects)):?>
			<td>Select project</td>
			<td>
				<select name="project" id="project_name">
				<?php foreach($projects as $p): ?>
					<option value="<?php echo $p['id']?>"><?php echo $p['name']?></option>
				<?php endforeach;?>
				</select>
			</td>
			<?php else:?>
				<td><input type="hidden" class="project_name" name="project_name" value="<?php echo $project['id']?>"></td>
			<?php endif;?>
			<td>Assign to </td>
			<td>
				<select name="assign_to" class="assign_user">
				<?php foreach($users as $user): ?>
					<option value="<?php echo $user['id']?>" label="<?php echo $user['displayname']?>"><?php echo $user['displayname']?></option>
				<?php endforeach;?>
				</select>
			</td>
			<td>Priority </td>
			<td>
				<select name="priority" class="task_priority">
				<?php foreach(Helper_MyConst::$PROJECT_PRIORITY_TABLE as $id => $key): ?>
					<option value="<?php echo $id?>"><?php echo $key?></option>
				<?php endforeach;?>
				</select>
			</td>
			<td>Expired: </td>
			<td><?php echo form::input('deadline', '', array('class'=> 'deadline'))?></td>
		</tr>
	</table>
	<table class="group">		
		<tr class="rowA">
			<td>Description: </td>
			<td><?php echo form::textarea('description','',array('rows' => 2, 'class'=>"task_description"))?></td>
			<td>
				<input type="button" value="Add" name="add" class="add_button">
				<a href="#" class="done_add_task">Done add task</a>	
			</td>
		</tr>
	</table>
	</form>
	*/?>
	<input type="hidden" name="group_id" class="group_id <?php echo $group_id?>" value="<?php echo $group_id?>">
	<input type="hidden" name="project_id" class="project_id <?php echo $project['id']?>" value="<?php echo $project['id']?>">
	<input type="hidden" name="user_displayname" class="user_displayname <?php echo $curr_user['displayname']?>" value="<?php echo $curr_user['displayname']?>">	



